package com.dragon.www.haier.util;

import java.util.List;
import java.util.Map;

/**
 * 集合或者数组的非空判断
 * @author YWL
 *
 */
public class CollectionUtils {
	
	public static boolean isNonempty(Object[] array) {
		if(array == null)
			return false;
		if(array.length == 0)
			return false;
		else 
			return true;
	}

	public static boolean isNonempty(List<?> list) {
		if(list == null)
			return false;
		if(list.size() == 0)
			return false;
		else 
			return true;
	}
	
	public static boolean isNonempty(Map<?, ?> map) {
		if(map == null)
			return false;
		if(map.size() == 0)
			return false;
		else 
			return true;
	}
}
